<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <!-- 、JSON字符串转js对象，js对象转JSON字符串 -->
</head>
<body>
  <h2>为 JSON 字符串创建对象</h2>
  <p id="demo"></p>
<script>
  let obj = {
    a:'11'
  }
  let str = JSON.stringify(obj)
  console.log(str);
  console.log(JSON.parse(str));
</script>
</body>
</html>
